package com.isoft.data.dao;

import com.isoft.data.xml.Cfie;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

@Mapper
public interface CfieDao {
    @Insert("INSERT INTO AIRPORT.META(SNDR,RCVR,SEQN,DDTM,TYPE,STYP)" +
            "VALUES(#{cfie.meta.sndr},#{cfie.meta.rcvr},"+
            "#{cfie.meta.seqn},#{cfie.meta.ddtm},"+
            "#{cfie.meta.type},#{cfie.meta.styp})")
    public int addMeta(@Param("cfie") Cfie cfie);
    @Insert("INSERT INTO AIRPORT.CFIE(SEQN,DDTM,CODE,CFTP,AWCD," +
            "STNM,RSTN,CFSA,TTWC,MXLW,RLLW)" +
            "VALUES(#{cfie.meta.seqn},#{cfie.meta.ddtm}," +
            "#{cfie.cfieCrft.code},#{cfie.cfieCrft.cftp}, #{cfie.cfieCrft.awcd}," +
            "#{cfie.cfieCrft.stnm},#{cfie.cfieCrft.rstn}, #{cfie.cfieCrft.cfsa}," +
            "#{cfie.cfieCrft.ttwc}, #{cfie.cfieCrft.mxlw}, #{cfie.cfieCrft.rllw})")
    public int addCfie(@Param("cfie") Cfie cfie);
}
